<?php if (!defined('THINK_PATH')) exit();?>
<div class="page-group">

      <div class="page  pay-content">
        <header class="bar bar-nav">
          <a class="button button-link button-nav pull-left back"   data-transition='slide-out'>
                <span class="icon icon-left"></span>
                返回
              </a>
          <h1 class="title">订单确认</h1>
        </header>
        <nav class="bar bar-tab cart-bar">
          <div class="pay-price">待支付<span class="priceTotal"></span></div>
          <a class="pay-cart">提交订单</a>
        </nav>
        <div class="content content-padded">

          <div class=" list-block">
            <ul>
              <li class="item-content">
                 <div class="item-inner">
                   <div class="item-title"><span class="iconfont">&#xe60d;</span>选择用餐时间</div>
                 </div>
               </li>
               <li class="item-content">
                  <div class="item-inner">
                    <input type="text" id='datetime-picker' placeholder="点击设置时间"/>
                  </div>
                </li>
            </ul>
          </div>
          <div class=" list-block ">
            <ul class="sel-foods">
            </ul>
          </div>
          <div class=" list-block ">
            <ul>
              <li class="item-content">
                 <div class="item-inner">
                   <div class="item-title">总价</div>
                   <div class="item-after priceTotal"></div>
                 </div>
               </li>
            </ul>
          </div>
          <div class="address list-block no-margin">
            <h3>用户信息</h3>
            <ul>
              <li class="item-content">
                 <div class="item-inner">
                   <div class="item-title">姓名</div>
                   <div class="item-after ">马召林</div>
                 </div>
               </li>
               <li class="item-content">
                  <div class="item-inner">
                    <div class="item-title">电话</div>
                    <div class="item-after ">18983367454</div>
                  </div>
                </li>
                <li class="item-content">
                   <div class="item-inner">
                     <div class="item-title">地址</div>
                     <div class="item-after ">啊实打实大声道</div>
                   </div>
                 </li>
            </ul>
          </div>

          <script type="text/javascript">
          app.initPay();
          $("#datetime-picker").datetimePicker({});
          $('.pay-cart').click(function(){
            $.getJSON('<?php echo U("Order/createAction");?>',{data:JSON.stringify(app.getCart())},function(res){
                $.alert(res.msg,function(){
                  if(res.code==1){
                    app.clearCart();
                    location.href="<?php echo U('Order/index');?>";
                  }
                });

            })
          })
          </script>
        </div>

        </div>

   </div>